package org.example.service.impl;

import org.example.service.OrderService;
import org.springframework.stereotype.Service;

@Service
public class OrderServiceImpl implements OrderService {
    @Override
    public void add(String pname, int number) {
        System.out.println("添加 " + number + " 个 " + pname + " 到购物车");
    }

    @Override
    public void delete(String pname) {
        System.out.println("从购物车删除 " + pname);
    }

    @Override
    public int find(String pname) {
        System.out.println("查询购物车中 " + pname + " 的数量");
        return 3; // 模拟数量为3
    }
}